<?php

/**
 * User form.
 *
 * @package    ProdAssistant
 * @subpackage form
 * @author     Paweł Świtalla
 * @version    SVN: $Id: sfDoctrineFormTemplate.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class UserForm extends BaseUserForm
{
  public function configure()
  {
    $core = PACore::getInstance();
    $this->useFields(array(
        'firstName',
        'lastName',
        'number',
        'mobile',
        'login',
        'password',
        'email',
        'role_id',
        'position'
    ));
    $this->widgetSchema['firstName']->setLabel("Imię");
    $this->widgetSchema['lastName']->setLabel("Nazwisko");
    $this->widgetSchema['number']->setLabel("Telefon");
    $this->widgetSchema['mobile']->setLabel("Kom.");
    $this->widgetSchema['password']->setLabel("Hasło");
    //$this->widgetSchema['role_id']->setLabel('Rola <br /><a onclick="App.loadWindow(\'http://127.0.0.1/Core_dev.php/getComponent/Entry/manageRoles/refreshLastForm\', undefined, App.Table.refreshLastForm)" class="active"><img src="/images/icons/add.png" class="middle" height="18" width="18"></a>');
    $this->widgetSchema['role_id']->setLabel('Rola <br /><a onclick="App.loadWindow(\''.$core->generateAppUrl('Core', 'homeGetComponent', true, array('componentModule' => 'Entry', 'name' => 'manageRoles', 'handler' => 'refreshLastForm')).'\')" class="active"><img src="/images/icons/add.png" class="middle" height="18" width="18"></a>');
    $this->widgetSchema['position']->setLabel("Stanowisko");  
  }
}
